Optical wireless communications (OWC) refers to all optical communication in which no cables (for example, fibers) are used. Visible light communication (VLC), infrared communication, and the like are all communication manners in the optical wireless communications. The VLC is a manner of communication by using visible light spectra (380 nm to 780 nm). In the VLC, a signal is transmitted mainly by modulating intensity of a light emitting diode (LED) light source. At an input end, a transmitter encodes and modulates a to-be-transmitted data signal, where the encoded and modulated data signal is used to modulate intensity of an LED light source, to generate a light intensity modulation signal. At a receive end, a photodetector or an optical camera (OC) is used to detect the received light intensity modulation signal, convert the received light intensity modulation signal into an electrical signal, and input the converted electrical signal into a receiver. The receiver demodulates and decodes the electrical signal, and restores and outputs the transmitted data signal.
The Institute of Electrical and Electronics Engineers (IEEE) released the IEEE 802.15.7 standard in 2011. The standard is applicable to visible light communication. An IEEE 802.15.7 network is referred to as a visible light communication personal area network (VPAN). Each star VPAN has a serving node and a plurality of terminal nodes. The serving node is referred to as a coordinator (coordinator), configured to manage running of the VPAN.
In an OWC network, a coordinator may perform network resource and transmission scheduling based on a superframe or a Media Access Control (MAC) cycle. A superframe includes an active period and an inactive period. The active period includes a beacon timeslot used for sending a beacon, a contention access period (CAP), and a contention free period (CFP). Each MAC cycle may be divided into a contention-free transmission opportunity (CFTXOP) and a shared transmission opportunity (STXOP). The STXOP may include a contention-free timeslot (CFTS) and a contention-based timeslot (CBTS).
In the VPAN, when the coordinator communicates with a terminal node in a CAP or a CBTS, the communication may be performed in a carrier sense multiple access with collision avoidance (CSMA/CA) manner. In the CSMA/CA manner, the terminal node first listens to a channel, determines whether there is another terminal node using the channel (transmission is being performed), and if detecting that the channel is idle, sends data after waiting a period of time. If the terminal node finds, through listening, that the channel is being used, the terminal node uses a random backoff algorithm. A backoff counter counts down provided that the channel is idle. When the backoff counter is decremented to 0, the terminal node performs sending and waits for confirmation.
In uplink communication, because contention-based transmission is performed in the CSMA/CA manner, the coordinator does not know in advance which terminal node can successfully contend for a channel, and does not know a sending bandwidth used when the terminal node performs transmission. In this case, if a plurality of terminal nodes support different bandwidths, the coordinator does not know to use which bandwidth for signal receiving and processing.